var express = require('express');
var router = express.Router();
var UserController = require('../controllers/UserController');

exports.init = function (app) {
  app.use(router);
};

router.get('/u/:user', UserController.user);
router.post('/post', UserController.post);
router.get('/reg', UserController.reg);
router.post('/reg', UserController.doReg);
router.get('/login', UserController.login);
router.post('/login', UserController.doLogin);
router.get('/logout', UserController.logout);